package com.aat.grab.rule.dao;

import java.io.Serializable;

import org.springframework.data.mongodb.core.query.Criteria;
import org.springframework.data.mongodb.core.query.Query;

public abstract class BaseRepository<T, ID extends Serializable> implements
		BaseDao<T, ID> {
	protected Query getIdQuery(ID id) {
		return Query.query(getIdCriteria(id));
	}

	protected Criteria getIdCriteria(ID id) {
		return Criteria.where("id").is(id);
	}

}
